package com.yonyou.pmclouds.siteinspection.entity;

import com.yonyou.pmclouds.basecom.entity.SuperVO;
import com.yonyou.pmclouds.inspectitem.entity.InspectItemVO;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.math.BigDecimal;
import java.util.Date;
@Table(name="pm_siteinspection")
@Setter
@Getter
public class SiteInspectionVO extends SuperVO{

    private static final long serialVersionUID = 2122300588258274262L;
    /**
     * 项目
     */
    public static String PK_PROJECT = "pk_project";
    /**
     * 工序
     */
    public static String PK_PROCESS = "pk_process";
    /**
     * 施工单位
     */
    public static String PK_CONSTRUCTIONUNIT = "pk_constructionunit";
    /**
     * 施工单位名称
     */
    public static String CONSTRUCTION_UNIT_NAME = "construction_name";
    /**
     * 检查标准
     */
    public static String PK_INSPECTSTANDARD = "pk_inspectstandard";
   /**
    * 制单人姓名
    */
    public static String CREATOR_NAME = "creator_name";
    /**
     * 制单人
     */
    public static String CREATOR = "creator";
    public static String PK_PROJECTPART = "pk_projectpart";

    public static final String INSPECT_AREA = "inspectarea";

    public static final String BILLSTATUS = "billstatus";

    /**
     * 需要包装属性的参照字段
     */
    public static String[] REF_FILEDS ={PK_PROJECT,PK_PROCESS,PK_CONSTRUCTIONUNIT,PK_INSPECTSTANDARD};
    
    
    /**
     * 现场检查单据字段
     */
    @Id
    private String pk_siteinspection;
    private String pk_project;
    private String pk_process;
    //施工单位
    private String pk_constructionunit;
    // 检查部位
    private String inspectarea;
    // 检查标准
    private String pk_inspectstandard;
    
    /** 前台页面显示字段**/
    @Transient
    private String inspectstandard_name;
    @Transient
    private String construction_name;
    @Transient
    private String project_name;
    @Transient
    private String project_code;
    @Transient
    private String contype_name;
    @Transient
    private String process_name;
    // 图片
    @Transient
    private String[] pictures;
    // 检查项
    @Transient
    private InspectItemVO[] inspectitems;
    // 制单人
    @Transient
    private String creator_name;

    private Date startDate;

    private Date endDate;
    /**
     * 合格率
     */
    private Double qualifiedRate;
    
    /** 通用字段**/
    @Column(name="pk_tenant",updatable=false)
    private String pk_tenant;
    @Column(name="creator",updatable=false)
    private String creator;
    @Column(name="creationtime",updatable=false)
    private Date creationtime;

    private String pkProjectpart;//工程部位
    @Transient
    private String projectpartName;

    private String modifier;
    private Date modifytime;
    // 经度
    private BigDecimal longitude;
    // 纬度
    private BigDecimal latitude;
    // 位置信息
    private String position;
    private String bill_type;
    private byte billstatus;
    @Transient
    private int totItemNum;
    @Transient
    private int passNum;
    @Transient
    private int unPassNum;
    @Transient
    private BigDecimal passRate;
 // 打印预览需要字符串日期
   @Transient
   private String strCreationtime;
   @Transient
   private String orgName;
   @Transient
   private String qualification_rate;
   @Transient
   private String strBillStatus;
   @Transient
   private String manager;
   @Transient
   private String managerName;

}
